package com.yzh.blog.dao;

import com.yzh.blog.pojo.Article;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @author yzh
 * @version 1.0
 * @description: TODO
 * @date 2022/4/15 11:18
 */
public interface ArticleDao {
    // 获取文章列表
    public List<Article> selectArticleList();
    // 根据文章的类别id获取类别
    public String selectCategoryByArtCateId(String id);
    // 根据文章id获取标签
    public List<String> selectTags(String id);

    public void insertArticle(Article article);

    public List<String> selectAllCategory();

    public int selectCategoryIdByArticleCatgoryName(String category);

    public void updateArticleType(@Param("id") String id, @Param("category_id") int category_id);

    public void InsertArticleTags(@Param("id") String id, @Param("tag") String tag);
}
